package mn.usi.spendcontrol.client;

import com.google.gwt.core.client.EntryPoint;
import com.google.gwt.event.logical.shared.ValueChangeEvent;
import com.google.gwt.event.logical.shared.ValueChangeHandler;
import com.google.gwt.user.client.History;
import com.google.gwt.user.client.ui.HTML;
import com.google.gwt.user.client.ui.RootPanel;

public class SpendControl implements EntryPoint {
	public void onModuleLoad() {
		
		String initToken = History.getToken();
    	
	    if (initToken.length() == 0) {
	      History.newItem("login");
	    }
		
		History.addValueChangeHandler(new HistoryListener());
		History.fireCurrentHistoryState();
	}
}
